#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QGraphicsItem>
#include <QGraphicsScene>
#include "world.h"

namespace Ui {
  class MainWindow;
}

class MainWindow : public QMainWindow
{
  Q_OBJECT

public:
  explicit MainWindow(QWidget *parent = 0);
  ~MainWindow();

private:
  void updateUI();

  Ui::MainWindow *ui;
  World *mWorld;
  //QGraphicsScene mScene;
  Vehicle *mSelectedVehicle;
  //QMap<QString, QGraphicsItem*> mVehicleGfxMap;
  QTimer *mTimer;
  bool mRealtimeSim;
  bool mIsPlaying;

public slots:
  void OnSpawnVehicle();
  void OnZoomIn();
  void OnZoomOut();
  void OnSimSpeedSlider(int speed);
  void OnTimer();
  void OnTracking(bool value);
  void OnShowVectors(bool value);
  void OnShowForces(bool value);
  void OnSelectionOnly(bool value);
  void OnSelectionChanged();
  void OnLoadScenario();
  void OnClearScenario();
  void OnSimBegin();
  void OnSimEnd();
  void OnSimBack();
  void OnSimForward();
  void OnSimPlayStop();
  void OnLoadTrafficControls();
  void OnMenuAction(QAction *action);
  void OnRunInRealTime(bool value);
};

#endif // MAINWINDOW_H
